Grub2 SVN on 64bit Xserve 2,1
Hello all,
recently, we tried to use Grub2 SVN on a 64bit Apple Xserve (Model 2,1) using EFI and after Bean solved some Xserve specific problems that were discussed on the Ubuntu forums (http://ubuntuforums.org/showthread.php?t=995704) someone else finally managed to boot his Xserve 2,1 model with Grub2.
Ours however, did not boot and we isolated the problem to be a memory problem: When we plug in 4 GB or more, Grub2 fails (when you finally type "boot" on the command line, the machine instantly reboots). If we remove all but 2 GB of RAM, it works and we managed to boot a Debian kernel. So this seems to be a bug which only appears on this type of machine with >= 4GB of RAM.
Unfortunately, I haven't found a way yet to get any debug output for you from the machine (serial console doesn't seem to be supported in EFI). If there is anything we can do to get this bug solved, please let us know.
If this is the wrong list for this discussion, I'm sorry, I wasn't sure which list discusses Grub2 SVN bugs/problems :)
Thanks in advance,
Christian Holler
System Administrator
Saarland University
Hello
I don't know much about this.
However, you're compiling it on a 64-bit kernel, right?
The limitation you are talking about is the 32-bit 2 64-bit limitation. 32-bit only supports up to 3.25GB of RAM.
Have you tried compiling it on 32-bit os? That may (for some reason) fix the problem.
Give it a go.
Panarchy
---------- Forwarded message ----------
From: decoder <[email protected]>
Date: Thu, Apr 23, 2009 at 7:49 PM
Subject: Grub2 SVN on 64bit Xserve 2,1
To: [email protected]
Cc: [email protected]
Hello all,
recently, we tried to use Grub2 SVN on a 64bit Apple Xserve (Model 2,1) using EFI and after Bean solved some Xserve specific problems that were discussed on the Ubuntu forums
(http://ubuntuforums.org/showthread.php?t=995704) someone else finally managed to boot his Xserve 2,1 model with Grub2.
Ours however, did not boot and we isolated the problem to be a memory
problem: When we plug in 4 GB or more, Grub2 fails (when you finally type "boot" on the command line, the machine instantly reboots). If we remove all but 2 GB of RAM, it works and we managed to boot a Debian kernel. So this seems to be a bug which only appears on this type of machine with >= 4GB of RAM.
Unfortunately, I haven't found a way yet to get any debug output for you from the machine (serial console doesn't seem to be supported in EFI). If there is anything we can do to get this bug solved, please let us know.
If this is the wrong list for this discussion, I'm sorry, I wasn't sure which list discusses Grub2 SVN bugs/problems :)
Thanks in advance,
Christian Holler
System Administrator
Saarland University
_______________________________________________
Grub-devel mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/grub-devel
Quoted 41 lines · decoder
Hello all,
recently, we tried to use Grub2 SVN on a 64bit Apple Xserve (Model 2,1) using EFI and after Bean solved some Xserve specific problems that were discussed on the Ubuntu forums
(http://ubuntuforums.org/showthread.php?t=995704) someone else finally managed to boot his Xserve 2,1 model with Grub2.Ours however, did not boot and we isolated the problem to be a memory
problem: When we plug in 4 GB or more, Grub2 fails (when you finally type "boot" on the command line, the machine instantly reboots). If we remove all but 2 GB of RAM, it works and we managed to boot a Debian kernel. So this seems to be a bug which only appears on this type of machine with >= 4GB of RAM.Unfortunately, I haven't found a way yet to get any debug output for you from the machine (serial console doesn't seem to be supported in EFI). If there is anything we can do to get this bug solved, please let us know.
If this is the wrong list for this discussion, I'm sorry, I wasn't sure which list discusses Grub2 SVN bugs/problems :)
Thanks in advance,
Christian Holler
System AdministratorSaarland University
_______________________________________________
Grub-devel mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/grub-devel
Hi,
yes I am compiling grub on a 64 bit kernel and with x86_64 as target (--with-platform=efi --target=x86_64)
Compiling on a 32 bit machine does not succeed because the Xserve 2,1 does not accept 32 bit EFI images.
Best regards,
Chris
Quoted 120 lines · Chip Panarchy
Hello
I don't know much about this.
However, you're compiling it on a 64-bit kernel, right?
The limitation you are talking about is the 32-bit 2 64-bit limitation. 32-bit only supports up to 3.25GB of RAM.
Have you tried compiling it on 32-bit os? That may (for some reason) fix the problem.
Give it a go.
Panarchy
---------- Forwarded message ----------
From: decoder <[email protected]>
Date: Thu, Apr 23, 2009 at 7:49 PM
Subject: Grub2 SVN on 64bit Xserve 2,1
To: [email protected]
Cc: [email protected]Hello all,
recently, we tried to use Grub2 SVN on a 64bit Apple Xserve (Model 2,1) using EFI and after Bean solved some Xserve specific problems that were discussed on the Ubuntu forums
(http://ubuntuforums.org/showthread.php?t=995704) someone else finally managed to boot his Xserve 2,1 model with Grub2.Ours however, did not boot and we isolated the problem to be a memory
problem: When we plug in 4 GB or more, Grub2 fails (when you finally type "boot" on the command line, the machine instantly reboots). If we remove all but 2 GB of RAM, it works and we managed to boot a Debian kernel. So this seems to be a bug which only appears on this type of machine with >= 4GB of RAM.Unfortunately, I haven't found a way yet to get any debug output for you from the machine (serial console doesn't seem to be supported in EFI). If there is anything we can do to get this bug solved, please let us know.
If this is the wrong list for this discussion, I'm sorry, I wasn't sure which list discusses Grub2 SVN bugs/problems :)
Thanks in advance,
Christian Holler
System AdministratorSaarland University
_______________________________________________
Grub-devel mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/grub-develQuoted 33 lines · decoder
Hello all,
recently, we tried to use Grub2 SVN on a 64bit Apple Xserve (Model 2,1) using EFI and after Bean solved some Xserve specific problems that were discussed on the Ubuntu forums
(http://ubuntuforums.org/showthread.php?t=995704) someone else finally managed to boot his Xserve 2,1 model with Grub2.Ours however, did not boot and we isolated the problem to be a memory
problem: When we plug in 4 GB or more, Grub2 fails (when you finally type "boot" on the command line, the machine instantly reboots). If we remove all but 2 GB of RAM, it works and we managed to boot a Debian kernel. So this seems to be a bug which only appears on this type of machine with >= 4GB of RAM.Unfortunately, I haven't found a way yet to get any debug output for you from the machine (serial console doesn't seem to be supported in EFI). If there is anything we can do to get this bug solved, please let us know.
If this is the wrong list for this discussion, I'm sorry, I wasn't sure which list discusses Grub2 SVN bugs/problems :)
Thanks in advance,
Christian Holler
System AdministratorQuoted 9 lines
Saarland University
_______________________________________________
Grub-devel mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/grub-devel_______________________________________________
Grub-devel mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/grub-devel
You need to transform the code which switches to i386 into a trampoline in i386/efi/linux.c and i386/linux.c. I have no time to do it now. However I attach 2 patches with this mail which should help you. Apply only one of them (each of them tries a quick hack in a different way).
Quoted 146 lines · decoder
Hi,
yes I am compiling grub on a 64 bit kernel and with
x86_64as target (--with-platform=efi --target=x86_64)Compiling on a 32 bit machine does not succeed because the Xserve 2,1 does not accept 32 bit EFI images.
Best regards,
Chris
Quoted 119 lines · Chip Panarchy
Hello
I don't know much about this.
However, you're compiling it on a 64-bit kernel, right?
The limitation you are talking about is the 32-bit 2 64-bit limitation. 32-bit only supports up to 3.25GB of RAM.
Have you tried compiling it on 32-bit os? That may (for some reason) fix the problem.
Give it a go.
Panarchy
---------- Forwarded message ----------
From: decoder <[email protected]>
Date: Thu, Apr 23, 2009 at 7:49 PM
Subject: Grub2 SVN on 64bit Xserve 2,1
To: [email protected]
Cc: [email protected]Hello all,
recently, we tried to use Grub2 SVN on a 64bit Apple Xserve (Model 2,1) using EFI and after Bean solved some Xserve specific problems that were discussed on the Ubuntu forums
(http://ubuntuforums.org/showthread.php?t=995704) someone else finally managed to boot his Xserve 2,1 model with Grub2.Ours however, did not boot and we isolated the problem to be a memory
problem: When we plug in 4 GB or more, Grub2 fails (when you finally type "boot" on the command line, the machine instantly reboots). If we remove all but 2 GB of RAM, it works and we managed to boot a Debian kernel. So this seems to be a bug which only appears on this type of machine with >= 4GB of RAM.Unfortunately, I haven't found a way yet to get any debug output for you from the machine (serial console doesn't seem to be supported in EFI). If there is anything we can do to get this bug solved, please let us know.
If this is the wrong list for this discussion, I'm sorry, I wasn't sure which list discusses Grub2 SVN bugs/problems :)
Thanks in advance,
Christian Holler
System AdministratorSaarland University
_______________________________________________
Grub-devel mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/grub-develQuoted 35 lines · decoder
Hello all,
recently, we tried to use Grub2 SVN on a 64bit Apple Xserve (Model 2,1) using EFI and after Bean solved some Xserve specific problems that were discussed on the Ubuntu forums
(http://ubuntuforums.org/showthread.php?t=995704) someone else finally managed to boot his Xserve 2,1 model with Grub2.Ours however, did not boot and we isolated the problem to be a memory
problem: When we plug in 4 GB or more, Grub2 fails (when you finally type "boot" on the command line, the machine instantly reboots). If we remove all
but 2 GB of RAM, it works and we managed to boot a Debian kernel. So this seems to be a bug which only appears on this type of machine with >= 4GB of
RAM.Unfortunately, I haven't found a way yet to get any debug output for you from the machine (serial console doesn't seem to be supported in EFI). If there is anything we can do to get this bug solved, please let us know.
If this is the wrong list for this discussion, I'm sorry, I wasn't sure which list discusses Grub2 SVN bugs/problems :)
Thanks in advance,
Christian Holler
System AdministratorQuoted 10 lines
Saarland University
_______________________________________________
Grub-devel mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/grub-develQuoted 6 lines
_______________________________________________
Grub-devel mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/grub-devel
Quoted 6 lines
_______________________________________________
Grub-devel mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/grub-devel
loader/i386/efi/linux.c +9 -3
@@ -418,9 +418,6 @@ grub_linux_boot (void)/* Hardware interrupts are not safe any longer. */ asmvolatile ("cli" : : ); -/* Load the IDT and the GDT for the bootstrap. */ - asmvolatile ("lidt %0" : :"m" (idt_desc)); - asmvolatile ("lgdt %0" : :"m" (gdt_desc));#ifdef __x86_64__
@@ -430,10 +427,19 @@ grub_linux_boot (void) asmvolatile ("mov %0, %%rbx" : :"m" (params->code32_start)); asmvolatile ("mov %0, %%rsi" : :"m" (real_mode_mem)); +/* Load the IDT and the GDT for the bootstrap. */ + asmvolatile ("lidt %0" : :"m" (idt_desc)); + asmvolatile ("lgdt %0" : :"m" (gdt_desc)); + asmvolatile ("ljmp *%0" : :"m" (jumpvector));#else +/* Load the IDT and the GDT for the bootstrap. */ + asmvolatile ("lidt %0" : :"m" (idt_desc)); + asmvolatile ("lgdt %0" : :"m" (gdt_desc)); + +/* Pass parameters. */ asmvolatile ("movl %0, %%ecx" : :"m" (params->code32_start)); asmvolatile ("movl %0, %%esi" : :"m" (real_mode_mem));
kern/efi/mm.c +4 -1
@@ -73,7 +73,10 @@ grub_efi_allocate_pages (grub_efi_physical_address_t address, type =GRUB_EFI_ALLOCATE_ADDRESS ;#else if (address ==0 ) - type =GRUB_EFI_ALLOCATE_ANY_PAGES ; + { + type =GRUB_EFI_ALLOCATE_MAX_ADDRESS ; + address =0xffffffff ; + }else type =GRUB_EFI_ALLOCATE_ADDRESS ;#endif